<!DOCTYPE html>
<html>
<head>
	<title></title>
	<meta charset="utf-8">
</head>
<body>
<script src="https://cdn.bootcss.com/vue/2.3.4/vue.js"></script>
<div id="root">
	<button @click="getTag">获取标签内容</button>
    <h1>{{message}}</h1>
</div>
<script>
	var vm = new Vue({
        el:"#root",
        data:{
            message:"我爱北京天安门"
        },
        methods:{
            getTag:function(){
                this.message='我爱我家';
                console.log(document.querySelector('h1').innerHTML)
                
            }
        }
    });
</script>
</body>
</html>